<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>TinyBox2 - JavaScript Modal Windows</title>
<link rel="stylesheet" href="style.css" />
<script type="text/javascript" src="tinybox.js"></script>
</head>
<body>
<div id="testdiv">
	<h1>TinyBox2 JavaScript Modal Windows</h1>
	<!--
	<h2>For complete details visit <a href="http://www.scriptiny.com/2011/03/javascript-modal-windows/">scriptiny.com</a>.</h2>
	-->
	<ul>
		<li onclick="TINY.box.show({html:'This is a warning!',animate:false,close:false,boxid:'error',top:5})">No Animation, No Close Button, Auto Width/Height, Custom Styling</li>
		<li onclick="TINY.box.show({url:'post.php',post:'id=16',width:200,height:100,opacity:20,topsplit:3})">Ajax Post, Fixed Width/Height, Light Mask, Custom Vertical Split</li>
		<li onclick="TINY.box.show({html:'The entry has been updated successfully!',animate:false,close:false,mask:false,boxid:'success',autohide:2,top:-14,left:-17})">Custom Position, No Mask, Auto-Hide</li>
		<li onclick="TINY.box.show({iframe:'http://www.scriptiny.com/',boxid:'frameless',width:750,height:450,fixed:false,maskid:'bluemask',maskopacity:40,closejs:function(){closeJS()}})">iFrame, Blue Mask, Absolute Position, Frameless, Close Callback</li>
		<li onclick="TINY.box.show({url:'ajax.html'})">Ajax, Advanced Functions</li>
		<li onclick="TINY.box.show({image:'images/rhino.jpg',boxid:'frameless',animate:true,openjs:function(){openJS()}})">Image, Load Callback</li>

		<li onclick="TINY.box.show({html:document.getElementById('content').innerHTML,post:'id=16',opacity:20,topsplit:3,closejs:function(){closeJS()}})">显示页面一部分内容</li>
	</ul>
</div>
<div id="content" style="display:none;">
	我是<input type="text" value="" id="contetnText" name="contetnText">内容
</div>
<script type="text/javascript">
//function openJS(){alert('loaded')}
function closeJS(){alert(document.getElementsByName('contetnText')[1].value)}
</script>
</body>
